{template 'app_header'}
<link rel="stylesheet" href="{MODULE_URL}template/mobile/app/css/linewell_app_qd.css">
<script src="{MODULE_URL}template/mobile/app/js/clipboard.min.js"></script>
<script type="text/javascript">
    $(function() {
        var clipboard = new Clipboard('.button_yes');
        clipboard.on('success', function(e) {

        });

        clipboard.on('error', function(e) {
        });
        $(".button_yes").click(function() {
            var insert_data = {};
            var name = $("#name").val();
            if (name == '' || undefined == name) {
                $("#code_pop .weui_cell").removeClass('weui_cell_warn')
                $("#name").parent().parent('.weui_cell').addClass('weui_cell_warn');
                _loading_toast._show("请填写您的姓名");
                return;
            }
            insert_data.name = $("#name").val();

            // var tel = $("#tel").val();
            // if (tel == '' || undefined == tel) {
            //     $("#code_pop .weui_cell").removeClass('weui_cell_warn')
            //     $("#tel").parent().parent('.weui_cell').addClass('weui_cell_warn');
            //     _loading_toast._show("请填写您的手机号码");
            //     return;
            // }
            // var phone = /^1([38]\d|4[57]|5[0-35-9]|7[06-8]|8[89])\d{8}$/;
            // if (!phone.test($("#tel").val())) {
            //     $("#code_pop .weui_cell").removeClass('weui_cell_warn')
            //     $("#tel").parent().parent('.weui_cell').addClass('weui_cell_warn');
            //
            //     _loading_toast._show("请填写正确的手机号码");
            //     return;
            // }
            // insert_data.tel = $("#tel").val();


            _meepoajax._ajax({
                do_it:'bd_winning',
                type: "POST",
                dataType: 'json',
                cache: false,
                formPata:insert_data,
                success:function(data) {
                    if(data.errno==0){
                        _loading_toast._show("查询成功");
                        setTimeout(function(){
                            location.href="./index.php?i=1&c=entry&t={php echo time()}&do=app_winning&m=meepo_xianchang&userId="+data.message;
                        },500);
                    }else if(data.errno==1){
                        setTimeout(function(){
                            location.href="./index.php?i=1&c=entry&t={php echo time()}&do=app_winning_qd&m=meepo_xianchang&userId="+data.message;
                        },500);
                    }else{
                        _loading_toast._show(data.message);
                    }
                }
            });
        });
    });
</script>
</head>
<body>
<img src="{$qd['avatar']}" width="0" height="0"   >
<div class="vgy_user">
    <div class="info2">
        <!--img class="touxiang" src="{$user['avatar']}"-->
        <p class="name">{$user['nick_name']}</p>
    </div>
    <div class="box">
        <h1>签到、中奖信息查询</h1>
        <div class="weui_cells weui_cells_form" style="border-bottom-right-radius:20px;border-bottom-left-radius:20px;margin-top:0px">
            <div class="weui_cell">
                <div class="weui_cell_hd"><label class="weui_label">姓名</label></div>
                <div class="weui_cell_bd weui_cell_primary">
                    <input class="weui_input" type="text" id="name" placeholder="请填写您的姓名">
                </div>
            </div>
            <!--div class="weui_cell">
                <div class="weui_cell_hd"><label class="weui_label">手机</label></div>
                <div class="weui_cell_bd weui_cell_primary">
                    <input class="weui_input" type="tel" id="tel" placeholder="请填写您的手机号码">
                </div>
            </div-->
            <div class="but_con">
                <button class="button_yes" data-clipboard-target=".hb" style="border: 1px solid #e00000;background-color: #e00000;">查询</button><p class="hb" style="color:#fff;">t5hwb126zn</p>
            </div>
        </div>
    </div>
</div>
<div style="position:fixed; z-index:-1;top:0; height:100%; width:100%; opacity:0.3; background:url({$user['avatar']}) no-repeat center top; background-size:100% auto;">
    <div class="bgs" ><img class="bgt" src="{$user['avatar']}"></div>
</div>
<div style="display:none">
    <script type="text/javascript">var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_stat_icon_1272883987'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s19.cnzz.com/stat.php%3Fid%3D1272883987%26show%3Dpic' type='text/javascript'%3E%3C/script%3E"));</script>
</div>
{template 'app_footer'}